package com.zhj.rabbitmq.demo.confirm;

import org.springframework.amqp.core.Message;
import org.springframework.amqp.rabbit.annotation.RabbitListener;
import org.springframework.stereotype.Component;

/**
 * @author zhengjibin
 * @version 1.0.0
 * @ClassName BackupQueueConsumer.java
 * @Description 备份队列消费者
 * @createTime 2023年03月25日 15:26:00
 */
@Component
public class BackupQueueConsumer {

    @RabbitListener(queues = {ConfirmRabbitmqConfig.BACKUP_QUEUE_NAME})
    public void backupConsumer(Message message){
        System.out.println("备份队列接收到消息："+new String(message.getBody()));
    }
}
